package com.neueduTotal.CardGame;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

public class CardTest {
    public static void main(String[] args) {
        //创建集合存储卡牌
        List<Card> cards = new ArrayList<>();
        //创建54张卡牌对象
        //13种点数牌
        for (int rank = Card.THREE; rank < Card.BLACK; rank++) {
            //每种牌4种花色
            for (int suit = 0; suit < Card.JOKER; suit++) {
                //将创建的52张基本牌填入集合
                cards.add(new Card(suit, rank));
            }
        }
        //添加两张王牌
        cards.add(new Card(Card.JOKER, Card.BLACK));
        cards.add(new Card(Card.JOKER, Card.COLOR));
        System.out.println(cards);
        //打乱牌的顺序
        Collections.shuffle(cards);
        System.out.println(cards);

    }
}
